<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ page isELIgnored="false" %>
<!DOCTYPE html>
<html>

	<head>
		
		<meta name="renderer" content="webkit|ie-comp|ie-stand">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<meta charset='utf-8'>
        <meta name="author" content="order by dede58.com"/>
		<meta http-equiv="Cache-Control" content="no-siteapp" />
		<title>游戏商城首页</title>
		<meta name="viewport" content="width=device-width,initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
		<meta http-equiv="Cache-Control" content="no-siteapp">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="mobile-web-app-capable" content="yes">
		<meta name="format-detection" content="telephone=no">
		<meta name="keywords" content="">
		<meta name="description" content="">
		<link rel="stylesheet" type="text/css" href="css/page.css" />
		<link rel="stylesheet" type="text/css" href="css/base.css" />
		<script type="text/javascript" src="js/jquery-3.6.0.js"></script>
		
		<script src="js/jquery-1.8.3.min.js" type="text/javascript"></script>
		<script type="text/javascript" src="js/jquery.SuperSlide.2.1.js"></script>		
		
		
		<script type="text/javascript">
			$(function(){
				/* 获取最新上架的4个游戏 */
				$.ajax({
					async:true,
					type:"GET",
					url:"../GamesServlet",
					data:{
						op:"newestgames",
					},
					contentType:"application/x-www-form-urlencoded",
					dataType:"json",
					success:function(result,status,xhr){
						$.each(result.data,function(index,games){
							let p = ".zx"+index+" img";
							let a = "#zx"+index;
							$(p).prop("src","/gamestore/FileDownloadServlet?type=image&fileName="+games.image);
							$(a).html("<p>"+
											games.gamesName+
											"<span>"+games.price+".<samp>00</samp></span>"+
										"</p>");
							/* 对最新游戏图片设置跳转游戏详情页面顺便传入该游戏信息 */
							let n = "#new"+index;
							$(n).prop("href", "pro_detail.jsp?gamesId="+games.gamesId);
						});						
					},
				});
				/* 获取好评次数最多的6个推荐游戏 */
				
				$.ajax({
					async:true,
					type:"GET",
					url:"../GamesServlet",
					data:{
						op:"recommendgame"
					},
					contentType:"application/x-www-form-urlencoded",
					dataType:"json",
					success:function(result,status,xhr){
						let content = "<a href=\"#\" class=\"choice-more\">MORE+</a>";
						
						$.each(result.data,function(index,games){
							content += "<div class=\"list clearfix transition\" style=\"margin-right: 25px;\" id=\"gi\">"+
										"<div class=\"tu clearfix\">"+
										"<img  id=\"recommendedimages\" src=\"/gamestore/FileDownloadServlet?type=image&fileName="+games.image+"\"/>"+
										"<span></span>"+
										
										"<div class=\"ycang clearfix\">"+
											"<samp class=\"opa8\"></samp>"+
											"<div class=\"nr clearfix\">"+
												/* 注意：当下方li中添加class名为cur的时候为选中的时候样式 */
												"<ul>"+
													"<li class=\"box-s transition\" style=\"margin-left: 80px;\">在售</li>"+
													/* "<li class=\"box-s transition\">"+
													下面的id原来是addShop
														"<a href=\"javascript:void(0);\" class=\"box-s\" id=\"\">"+
															"购物车"+
														"</a>"+
													"</li>"+  */
												"</ul>"+
												"<input type=\"hidden\" id=\"id\" name=\"gamesId\" value=\""+games.gamesId+"\">"+
											"</div>"+							
										"</div>"+
									"</div>"+
									
									"<div class=\"xia clearfix box-s\">"+
										"<p class=\"bt over\">"+
											games.gamesName+
										"</p>"+
										"<div class=\"price clearfix\">"+
											"<span class=\"fl\" id=\"gp\">￥"+games.price+"</span>"+
											"<span id=\"agp\"><a id=\"ljgm\" href=\"javascript:void(0)\" class=\"goumai fr ra3 transition\">立即购买</a></span>"+

										"</div>"+
									"</div>"+
								"</div>";
								/* 查询用户是否已购买 */
								let cid = ${!empty sessionScope.customer.customerId} ?　"${sessionScope.customer.customerId}" : 0;
								let gamesId = games.gamesId;	
								$.ajax({
									async:true,
									type:"GET",
									url:"../OrderServlet",
									data:{
										op:"findByStatusAndGamesIdAndCustomerId",
										status:"1",
										gamesId:gamesId,
										customerId:cid
									},
									contentType:"application/x-www-form-urlencoded",
									dataType:"json",
									success:function(result,status,xhr){
										
										if(result.status == 1){
											$("#recommended").children("div").each(function(i,recommend){
												
												if(i==index){
													if($(this).find("input[name='gamesId']").val()==gamesId){
														$(this).find("#agp").html("<a href=\"javascript:void(0)\" class=\"goumai fr ra3 transition\" style=\"background-color: green;\">已购买</a>");
													}else{
														$(this).find("#agp").html("<a id=\"ljgm\" href=\"javascript:void(0)\" class=\"goumai fr ra3 transition\">立即购买</a>");
													}
												}
												
											});
											
											
										}
											
									},
							     });
								
								
								
						});	

						$(".tj").html(content);
					},
				});
				/* 对推荐游戏的图片所在区域recommendedimages绑定跳转详情页面 */
				$(document).on("click","#recommendedimages",function(){
					let gameId = $(this).siblings("div").find("input").val();
					location.href="pro_detail.jsp?gamesId="+gameId;
				})
				
				/* var interval = setInterval(function () {
		            console.log("调用iCheck");
		            if(document.readyState=="complete"){
					
		                clearInterval(interval);
		            }
		        },2000); */
		        
		        
				
				
				
	
				
				
				
				
				
				
			});
		</script>
		
		<script>
		$(function(){
			$(document).on("click","#ljgm",function(){
				let cid = ${!empty sessionScope.customer.customerId} ?　"${sessionScope.customer.customerId}" : 0;
				let gamesId = $(this).parents("#gi").find("input[name='gamesId']").val();
				if(cid!=0){
					location.href="jiesuan.jsp?gamesId="+gamesId;
				}else{
					alert("请先登录");
				}
				
			});
		})
		</script>
		
		
		
		
		<script type="text/javascript">
		/* $(function(){
		let cid = ${!empty sessionScope.customer.customerId} ?　"${sessionScope.customer.customerId}" : 0;
			// 在加入购物车之前查询用户的订单中是否已经存在该游戏
			$("#addShop").click(function(){
				let id = $(this).siblings().val();
				$.ajax({
					async:true,
					type:"GET",
					url:"../OrderServlet",
					data:{
						op:"repeat",
						status:"1"
						gamesId:id,
						customerId:cid
					},
					contentType:"application/x-www-form-urlencoded",
					dataType:"json",
					success:function(result,status,xhr){
						if(result.status == 1){
							$.ajax({
								async:true,
								type:"GET",
								url:"../OrderServlet",
								data:{
									op:"add",
									orderNo:"0",
									gamesId:id,
									customerId:cid
								},
								contentType:"application/x-www-form-urlencoded",
								dataType:"json",
								success:function(result,status,xhr){
									
									if(result.status == 1){
										//调用查询订单详情填充购物车
										s();
									}else{
										alert(result.message);
									}
									
								},
							});
							addShop();
							window.location.href="shopping.jsp?gamesId=${param.gamesId}";
						}else{
							alert("存在重复");
						}
						
					},
				});
			});
		}); */
		/* 在数据库生成一条订单号为0的订单详情 */
		function addShop(){
			
		}
		
		</script>
		
		
		<script>
		$(function(){
			let nickname = "${sessionScope.customer.nickname}";
			let content = "";
			if(nickname!=""){
				content = "<span class=\"fl\">欢迎</span>"+
						"<a href=\"grxx.jsp\" class=\"fl\">"+nickname+"</a>"+
						"<span class=\"fl\">进入商城</span>"+
						"<a href=\"../LoginServlet?op=customerLogout\" class=\"fl\">退出登陆</a>";
			}else{
				content = "<span class=\"fl\">您好，请</span>"+
						"<a href=\"sign.jsp\" class=\"fl\">登录</a>";
			}
			$("#customerInfo").html(content);
			
			
			$(document).on("click","#shopCount",function(){
				if(nickname!=""){
					$(this).prop("href","shopping.jsp");
				}else{
					alert("请先登录");
				}
			});
			
			
			
		});
			
		</script>
		<script type="text/javascript">
		$(function(){
			/* 创建一个查询方法通过游戏编号查询游戏信息添加入购物车*/
			let cid = ${!empty sessionScope.customer.customerId} ?　"${sessionScope.customer.customerId}" : 0;
			
			function s(){
				$.ajax({
					async:true,
					type:"GET",
					url:"../OrderServlet",
					data:{
						op:"find",
						orderNo:"0",
						customerId:cid
					},
					contentType:"application/x-www-form-urlencoded",
					dataType:"json",
					success:function(result,status,xhr){
						let count = 0;
						$.each(result.data,function(index,games){
							count = index + 1;
						});
						$("#shopCount").text("购物车（"+count+"）");
					},
					
				});	
			}
			if(cid!=0){
				/* 调用方法通过游戏编号查询游戏信息添加入购物车*/
				s();	
			}
			
		});
		</script>
	</head>
	
	<body>
		<!--header star-->
		<div class="header clearfix">			
			<div class="top clearfix">
				<div class="topctent clearfix">
					<div class="left clearfix fl">
						公告：您好，欢迎登录游戏商场
					</div>
					<div class="right clearfix fr">
						<div class="zuo clearfix fl">
							<ul class="clearfix fl">
								<li id = "customerInfo">
								
									<!-- <span class="fl">欢迎</span>
									<a href="grxx.jsp" class="fl">瑾晨0212</a>
									<span class="fl">进入商城</span> -->
									
									<!-- <span class="fl">您好，请</span>
									<a href="sign.jsp" class="fl">登录</a> -->
									
									
									
								</li>
								
								<li>
									<a href="register.jsp">
										免费注册
									</a>
								</li>
								<li>
									<a href="settled.html">
										商家入驻
									</a>
								</li>
							</ul>
						</div>						
						<div class="shopcar-btn clearfix fl">
							<a href="javascript:void(0)" class="box-s" id="shopCount">
								购物车（0）
							</a>
						</div>
						<div class="fenxiang clearfix fl">
							<span class="fl">分享到：</span>
							<ul class="clearfix fl">
								<li><a href="#"><img src="img/sina.png"/></a></li>
								<li><a href="#"><img src="img/qq.png"/></a></li>
								<li><a href="#"><img src="img/wechat.png"/></a></li>
							</ul>
						</div>
					</div>					
				</div>
			</div>			
			<div class="bottom clearfix" style="">
				<div class="clearfix">
				<video loop="loop" autoplay="autoplay" preload="" muted="muted" src="https://a.sinaimg.cn/mintra/pic/2112130543/weibo_login.mp4" poster="https://a.sinaimg.cn/mintra/pic/2112130400/18weibo_login.png" class="LoginTopNav_video_1W33g" style="position: absolute; width: 1540px; right: -170px;"> 抱歉，您的浏览器不支持内嵌视频 </video>
					<!-- <div class="bnetIcon--3gWUG icon--1SZos" aria-hidden="true" style="color: #148eff;width: 130px;">
							<div class="iconSvg--7rod7" style="fill: currentColor;">
								<svg focusable="false" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 600 580.4">
									<path d="M473.5 197.6c-75.9-35.1-185.1-57.4-287.8-49.1 5.1-34 17.9-57.7 38.7-62.7 28.7-6.9 60 12 89.8 46.3 19.5 2.5 42.7 7 58.9 10.7C318.7 40.5 245.7-16.8 190.2 4.4 148 20.5 126.4 78.6 129 156.7c-55 11.7-97.9 32.5-125.4 62.4-1.4 1.6-4.5 5.7-3.4 7.6.9 1.5 3.6-.2 4.9-1 31.8-22.3 72.6-34.3 125.7-41.9 7.6 83.3 42.8 189 101.4 273.8-32 12.6-58.9 13.4-73.6-2.2-20.3-21.4-19.6-58-4.8-101-7.6-18.2-15.3-40.5-20.1-56.3-61.6 98.3-74.8 190.2-28.7 227.7 35.1 28.5 96.2 18.2 162.5-23.1 37.6 41.8 77.1 68.5 116.7 77.3 2.1.4 7.2 1.1 8.3-.8.9-1.5-2-3.1-3.3-3.7-35.2-16.4-66-45.7-99.1-87.9 68.4-48.2 142.3-131.6 186.4-224.7 26.9 21.5 41 44.3 34.9 64.9-8.4 28.3-40.4 46-85.1 54.6-12 15.7-27.4 33.5-38.7 45.6 115.8 4 202-30.5 211.4-89.1 7.2-44.6-32.4-92.4-101.3-129.2 17.4-53.5 20.8-101 8.6-139.7-.7-2-2.6-6.8-4.9-6.8-1.7 0-1.7 3.3-1.6 4.7 3.6 38.6-6.3 80-26.3 129.7zM260.2 444.3c-49-78.6-77.2-171.2-77.1-264.8 92.6-3.1 186.9 18.7 267.9 65.7-43.6 81.7-109.6 152.5-190.8 199.1z">
									</path>
								</svg>
							</div>
					</div>
					<a href="index.jsp" style="position: absolute;top: 0px;width: 130px;height: 120px;">
						
					</a> -->
				</div>
				<!-- <div class="search clearfix fr ra5">
					<input type="text" class="fl" name="" id="" value="" placeholder="请输入您要搜索的内容" />
					<input type="button" name="" id="" value="搜索" class="fl box-s" />
				</div> -->
			</div>
		</div>
		<!--header end-->
		
		<!--navbar star-->
		<div class="navbar clearfix" style="position: relative;background-color: rgba(0,191,255,0.5);">
			<div class="content clearfix">
				<ul style="height: 51px;"><!-- style="background-color: rgba(0,191,255,0.5);height: 51px;" -->
					<li class="cur"><a href="index.jsp">首页精选</a></li>
					<li><a href="error.jsp">游戏专场(待开放)</a></li>
					<li><a href="mall.jsp">游戏商城</a></li>
					<li><a href="error.jsp">游戏商家(待开放)</a></li>
				</ul>
			</div>
		</div>
		<!--navbar end-->
		
		<!--banner star-->
		<div class="banner">		
			<div class="bd">
				<ul>
					<li style="background:url(img/s1.jpg) #194982 center 0 no-repeat;"><a href="#"></a></li>
					<li style="background:url(img/s2.jpg) #15181e center 0 no-repeat;"><a href="#"></a></li>
					<li style="background:url(img/s3.jpg) #0b0b0b center 0 no-repeat;"><a href="#"></a></li>
					<li style="background:url(img/s4.jpg) #000000 center 0 no-repeat;"><a href="#"></a></li>
					<li style="background:url(img/mztg.png) #04304b center 0 no-repeat;"><a href="#"></a></li>
				</ul>
			</div>
			<div class="hd"><ul></ul></div>
		</div>
		<!--banner end-->
		
		<!--recom star-->
		<div class="recom clearfix">
			<div class="content clearfix">
				<div class="recom-tit clearfix">
					<p class="engtit ta-center">
						Newest Games
					</p>
					<div class="middle clearfix">
						<span class="line"></span>
						<span class="wenzi">最新游戏</span>
						<span class="line"></span>
					</div>
					<p class="fu-tit">
						好作品无需多说 你会由心的看清它的诉说
					</p>
				</div>
				<div class="bottom clearfix box-s">
					<div class="left clearfix fl">
						<div class="listone clearfix fl">
							<a href="pro_detail.jsp" id="new0"><!-- 点击图片跳转至详情页面 -->
								<!--备注：第一张图 宽度：418像素，高度：710像素-->
								<div class="tu clearfix zx0">
								
									<img src=""/>
									<span></span>
								</div>
								<div class="listxia clearfix ta-center">
									<h2 id="zx0">
										<p>
											孙瑾晨
											<span>00.<samp>00</samp></span>
										</p>
									</h2>
								</div>
							</a>
						</div>
						<div class="listone listtwo clearfix fl">
							<a href="pro_detail.jsp" id="new1">
								<!--备注：第二张图 宽度：438像素，高度：376像素-->
								<div class="tu clearfix zx1">
								
									<img src=""/>
									<span></span>
								</div>
								<div class="listxia clearfix ta-center">
									<h2 id="zx1">
										<p>
											孙瑾晨
											<span>00.<samp>00</samp></span>
										</p>
									</h2>
								</div>
							</a>
						</div>
					</div>
					<div class="right clearfix fr">
						<div class="listone listthree clearfix fl">
							<a href="pro_detail.jsp" id="new2">
								<!--备注：第三张图 宽度：530像素，高度：638像素-->
								<div class="tu clearfix zx2">
								
									<img src=""/>
									<span></span>
								</div>
								<div class="listxia clearfix ta-center">
									<h2 id="zx2">
										<p>
											孙瑾晨
											<span>00.<samp>00</samp></span>
										</p>
									</h2>
								</div>
							</a>
						</div>
						
						<div class="listone listfour clearfix fr">
							<a href="pro_detail.jsp" id="new3">
								<!--备注：第四张图 宽度：438像素，高度：480像素-->
								<div class="tu clearfix zx3">
								
									<img src=""/>
									<span></span>
								</div>
								<div class="listxia clearfix ta-center">
									<h2 id="zx3">
										<p>
											孙瑾晨
											<span>00.<samp>00</samp></span>
										</p>
									</h2>
								</div>
							</a>
						</div>
					</div>
				</div>
			</div>
		</div>
		<!--recom end-->
		
		<!--choice star-->
		<div class="choice clearfix">
			<div class="bgdian"></div>
			<div class="recom-tit clearfix">
				<p class="engtit ta-center">
					Recommended Games
				</p>
				<div class="middle clearfix">
					<span class="line"></span>
					<span class="wenzi">推荐游戏</span>
					<span class="line"></span>
				</div>
				<p class="fu-tit">
					游戏种类丰富
				</p>
			</div>
			<div class="content clearfix box-s tj" id="recommended">
				
				<!-- <div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="img/gsl.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition" id="collect">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							1尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="javascript:void(0)" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div>
				<div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="img/COD16.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											加入购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							2尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="pro_detail.jsp" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div>
				<div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="img/COD16-2.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											加入购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							3尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="pro_detail.jsp" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div>
				<div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="upload/1.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											加入购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							4尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="pro_detail.jsp" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div>
				<div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="upload/1.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											加入购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							5尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="pro_detail.jsp" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div>
				<div class="list clearfix transition">
					<div class="tu clearfix">
						<img src="upload/1.jpg"/>
						<span></span>
						
						<div class="ycang clearfix">
							<samp class="opa8"></samp>
							<div class="nr clearfix">
								注意：当下方li中添加class名为cur的时候为选中的时候样式
								<ul>
									<li class="box-s transition">收藏</li>
									<li class="box-s transition">
										<a href="shopping.jsp" class="box-s">
											加入购物车
										</a>
									</li>
								</ul>
							</div>								
						</div>
					</div>
					<div class="xia clearfix box-s">
						<p class="bt over">
							6尹毅画作
						</p>
						<div class="price clearfix">
							<span class="fl">￥00.00</span>
							<a href="pro_detail.jsp" class="goumai fr ra3 transition">立即购买</a>
						</div>
					</div>
				</div> -->
				
				
				
			</div>
		</div>
		<!--choice end-->
		<script>
			$(function(){
				/* 添加已购买标识 */
				let cid = ${!empty sessionScope.customer.customerId} ?　"${sessionScope.customer.customerId}" : 0;
				
				
				$("#recommended").children("div").each(function(index,d){
					
					let gamesId = $(this).find("input[name='gamesId']").val();
					
					
					
					
					
					
				 });
			});
		</script>
		<!--art star-->
		<div class="art clearfix">
			<div class="content clearfix box-s">
				<div class="art-ctent clearfix box-s">
					<div class="recom-tit clearfix">
						<p class="engtit ta-center">
							Popular Games
						</p>
						<div class="middle clearfix">
							<span class="line"></span>
							<span class="wenzi">热门游戏</span>
							<span class="line"></span>
						</div>
					</div>
					<div class="bottom clearfix box-s" style="width: 101%;">
						<div class="scrollBox" style="margin:0 auto">
							<div class="ohbox">
								<ul class="piclist" id="lb">
									<!-- <li>
										<div class="list clearfix fl box-s transition">
											<div class="tu clearfix box-s">
												<img src="img/gsl.jpg" style="width: 90px;position: absolute;left: 70px;top: -70px;"/>
												<span></span>
											</div>
											<div class="ctent clearfix box-s">
												<div class="shang clearfix">
													<p class="over ta-center">孙瑾晨</p>
													<span></span>
												</div>
												<div class="xia clearfix">
													<p>
														原名查君，生于西安，自幼受家庭熏陶，随父习画1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中......
													</p>
												</div>
											</div>
										</div>
									</li>
									<li>
										<div class="list clearfix fl box-s transition">
											<div class="tu clearfix box-s">
												<img src="img/COD16-2.jpg"/>
												<span></span>
											</div>
											<div class="ctent clearfix box-s">
												<div class="shang clearfix">
													<p class="over ta-center">孙瑾晨</p>
													<span></span>
												</div>
												<div class="xia clearfix">
													<p>
														原名查君，生于西安，自幼受家庭熏陶，随父习画1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中......
														<a href="#" class="more">
															查看更多&gt;&gt;
														</a>
													</p>
												</div>
											</div>
										</div>
									</li>
									<li>
										<div class="list clearfix fl box-s transition">
											<div class="tu clearfix box-s">
												<img src="upload/people.jpg"/>
												<span></span>
											</div>
											<div class="ctent clearfix box-s">
												<div class="shang clearfix">
													<p class="over ta-center">孙瑾晨</p>
													<span></span>
												</div>
												<div class="xia clearfix">
													<p>
														原名查君，生于西安，自幼受家庭熏陶，随父习画1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中......
														<a href="#" class="more">
															查看更多&gt;&gt;
														</a>
													</p>
												</div>
											</div>
										</div>
									</li>
									<li>
										<div class="list clearfix fl box-s transition">
											<div class="tu clearfix box-s">
												<img src="upload/people.jpg"/>
												<span></span>
											</div>
											<div class="ctent clearfix box-s">
												<div class="shang clearfix">
													<p class="over ta-center">孙瑾晨</p>
													<span></span>
												</div>
												<div class="xia clearfix">
													<p>
														原名查君，生于西安，自幼受家庭熏陶，随父习画1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中
														原名查君，生于西安，自幼受家庭熏陶，随父习画。1986年入中......
														<a href="#" class="more">
															查看更多&gt;&gt;
														</a>
													</p>
												</div>
											</div>
										</div>
									</li> -->
								</ul>
							</div>
							<div class="pageBtn">
								<!-- <span class="prev">&lt;</span>
								<span class="next">&gt;</span> -->
								<ul class="list"><li>0</li><li>1</li></ul>
							</div>
						</div>
					</div>		
					
				</div>
			</div>
		</div>
		<!--art end-->
		<script type="text/javascript">
		/* 填充5个热门游戏 */
		
		$.ajax({
			async:true,
			type:"GET",
			url:"../GamesServlet",
			data:{
				op:"populargames",
			},
			contentType:"application/x-www-form-urlencoded",
			dataType:"json",
			success:function(result,status,xhr){
				let content = "";
				$.each(result.data,function(index,games){
					content += "<li>"+
								"<div class=\"list clearfix fl box-s transition\">"+
									"<div class=\"clearfix box-s\">"+
										"<img src=\"/gamestore/FileDownloadServlet?type=image&fileName="+games.image+"\" style=\"width: 90px;position: absolute;left: 70px;top: -18px;\"/>"+
									"<span></span>"+
								"</div>"+
								"<div class=\"ctent clearfix box-s\">"+
									"<div class=\"shang clearfix\">"+
										"<p class=\"over ta-center\">"+games.gamesName+"</p>"+
										"<span></span>"+
								     "</div>"+
										"<div class=\"xia clearfix\">"+
											"<p>"+games.content+"</p>"+
										"</div>"+
									"</div>"+
								"</div>"+
								"</li>";
					
				});	
				$("#lb").html(content);
			},
		});
		
		
		</script>
		<!--footer star-->
		<div class="footer clearfix">
			<div class="content clearfix">
				<div class="top clearfix">
					<div class="list clearfix fl box-s">
						<div class="part icon1 box-s">
							<h3>专业</h3>
							<p>拥有资深游戏顾问和先进交易平台，安全交易，快捷支付。</p>
						</div>
					</div>
					<div class="list clearfix fl box-s">
						<div class="part icon2 box-s">
							<h3>保真</h3>
							<p>阵容强大的游戏评鉴团，确保平台上的游戏货真价实。</p>
						</div>
					</div>
					<div class="list clearfix fl box-s">
						<div class="part icon3 box-s">
							<h3>保值</h3>
							<p>为您精选具备收藏价值的游戏作品，助您的资产保值、增值。</p>
						</div>
					</div>
				</div>
				<div class="bottom clearfix">
					<div class="left clearfix fl">
						<div class="list clearfix">
							<div class="shang clearfix">
								<p>新手指南</p>
								<span></span>
							</div>							
							<div class="xia clearfix">
								<ul>
									<li><a href="scgmlc.html">购买流程</a></li>
									<li><a href="cjwt.html">常见问题</a></li>
								</ul>
							</div>
						</div>
						<div class="list clearfix">
							<div class="shang clearfix">
								<p>账户管理</p>
								<span></span>
							</div>							
							<div class="xia clearfix">
								<ul>
									<li><a href="zhcz.html">账户充值</a></li>
									<li><a href="zhtx.html">账户提现</a></li>
									<li><a href="zffs.html">支付方式</a></li>
								</ul>
							</div>
						</div>						
						<div class="list clearfix">
							<div class="shang clearfix">
								<p>服务合作</p>
								<span></span>
							</div>							
							<div class="xia clearfix">
								<ul>
									<li><a href="friend-link.html">友情链接</a></li>
									<li><a href="ysjrz.html">玩家入驻</a></li>
								</ul>
							</div>
						</div>
						<div class="list clearfix">
							<div class="shang clearfix">
								<p>关于我们</p>
								<span></span>
							</div>							
							<div class="xia clearfix">
								<ul>
									<li><a href="gsjj.html">商城简介</a></li>
									<li><a href="contact.html">联系我们</a></li>
									<li><a href="jrwm.html">加入我们</a></li>
								</ul>
							</div>
						</div>
						<div class="list clearfix">
							<div class="shang clearfix">
								<p>售后服务</p>
								<span></span>
							</div>							
							<div class="xia clearfix">
								<ul>
									<li><a href="wlsm.html">交易说明</a></li>
									<li><a href="mzsm.html">免责声明</a></li>
								</ul>
							</div>
						</div>
					</div>
					<div class="middle clearfix fl">
						<ul>
							<li><img src="upload/ewm.jpg"/></li>
							<li><img src="upload/ewm.jpg"/></li>
						</ul>
					</div>
					<div class="right clearfix fr">
						<p class="bt">免费咨询热线：</p>
						<p class="tel">400-000-0000</p>
						<p class="fu-bt">(周一到周五8:00-22:00)</p>
					</div>
				</div>
			</div>
			<div class="banquan clearfix ta-center">
				Copyright © 2020 厦门游戏商城(xiamenyouxishangcheng). All Rights Reserved. 
			</div>
		</div>
		<!--footer end-->
	</body>
	<script src="js/other.js" type="text/javascript" ></script>
	
	
	
	
	
</html>
